.class Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;
.super Ljava/lang/Object;
.source "AccountSettingActivity.java"

# interfaces
.implements Landroid/widget/SimpleAdapter$ViewBinder;


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/netease/newsreader/activity/AccountSettingActivity;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x2
    name = "ButtonItem"
.end annotation


# instance fields
.field final synthetic this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;


# direct methods
.method private constructor <init>(Lcom/netease/newsreader/activity/AccountSettingActivity;)V
    .locals 0
    .parameter

    .prologue
    .line 355
    iput-object p1, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method

.method synthetic constructor <init>(Lcom/netease/newsreader/activity/AccountSettingActivity;Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;)V
    .locals 0
    .parameter
    .parameter

    .prologue
    .line 355
    invoke-direct {p0, p1}, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;-><init>(Lcom/netease/newsreader/activity/AccountSettingActivity;)V

    return-void
.end method


# virtual methods
.method public setViewValue(Landroid/view/View;Ljava/lang/Object;Ljava/lang/String;)Z
    .locals 8
    .parameter "view"
    .parameter "data"
    .parameter "key"

    .prologue
    const v7, 0x7f080027

    const/4 v3, 0x1

    const/4 v4, 0x0

    .line 363
    invoke-virtual {p1}, Landroid/view/View;->getId()I

    move-result v2

    const v5, 0x7f0c0014

    if-ne v2, v5, :cond_a

    .line 364
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    invoke-virtual {v2}, Lcom/netease/newsreader/activity/AccountSettingActivity;->getThemeSettingsHelper()Lcom/netease/newsreader/util/ThemeSettingsHelper;

    move-result-object v2

    iget-object v5, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    const v6, 0x7f020088

    invoke-virtual {v2, v5, p1, v6}, Lcom/netease/newsreader/util/ThemeSettingsHelper;->setViewBackgroud(Landroid/content/Context;Landroid/view/View;I)V

    .line 365
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    invoke-virtual {v2}, Lcom/netease/newsreader/activity/AccountSettingActivity;->getThemeSettingsHelper()Lcom/netease/newsreader/util/ThemeSettingsHelper;

    move-result-object v5

    iget-object v6, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    move-object v2, p1

    check-cast v2, Landroid/widget/TextView;

    invoke-virtual {v5, v6, v2, v7}, Lcom/netease/newsreader/util/ThemeSettingsHelper;->setTextViewColor(Landroid/content/Context;Landroid/widget/TextView;I)V

    .line 366
    const-string v1, ""

    .line 367
    .local v1, sql:Ljava/lang/String;
    const-string v2, "sina"

    invoke-virtual {p3, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v2

    if-eqz v2, :cond_2

    .line 368
    const-string v1, "select * from oauth_list where oauth_type=?"

    .line 371
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    iget-object v2, v2, Lcom/netease/newsreader/activity/AccountSettingActivity;->db:Landroid/database/sqlite/SQLiteDatabase;

    new-array v5, v3, [Ljava/lang/String;

    const-string v6, "sina"

    aput-object v6, v5, v4

    invoke-virtual {v2, v1, v5}, Landroid/database/sqlite/SQLiteDatabase;->rawQuery(Ljava/lang/String;[Ljava/lang/String;)Landroid/database/Cursor;

    move-result-object v0

    .line 372
    .local v0, cursor:Landroid/database/Cursor;
    if-eqz v0, :cond_1

    invoke-interface {v0}, Landroid/database/Cursor;->getCount()I

    move-result v2

    if-eqz v2, :cond_1

    move-object v2, p1

    .line 373
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u53d6\u6d88\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 374
    const-string v2, "sina_unbind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    .line 379
    :goto_0
    if-eqz v0, :cond_0

    invoke-interface {v0}, Landroid/database/Cursor;->close()V

    .line 435
    .end local v0           #cursor:Landroid/database/Cursor;
    :cond_0
    :goto_1
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    invoke-static {v2}, Lcom/netease/newsreader/activity/AccountSettingActivity;->access$5(Lcom/netease/newsreader/activity/AccountSettingActivity;)Landroid/view/View$OnClickListener;

    move-result-object v2

    invoke-virtual {p1, v2}, Landroid/view/View;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    move v2, v3

    .line 441
    .end local v1           #sql:Ljava/lang/String;
    .end local p1
    :goto_2
    return v2

    .restart local v0       #cursor:Landroid/database/Cursor;
    .restart local v1       #sql:Ljava/lang/String;
    .restart local p1
    :cond_1
    move-object v2, p1

    .line 376
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 377
    const-string v2, "sina_bind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    goto :goto_0

    .line 381
    .end local v0           #cursor:Landroid/database/Cursor;
    :cond_2
    const-string v2, "qq"

    invoke-virtual {p3, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v2

    if-eqz v2, :cond_4

    .line 382
    const-string v1, "select * from oauth_list where oauth_type=?"

    .line 385
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    iget-object v2, v2, Lcom/netease/newsreader/activity/AccountSettingActivity;->db:Landroid/database/sqlite/SQLiteDatabase;

    new-array v5, v3, [Ljava/lang/String;

    const-string v6, "qq"

    aput-object v6, v5, v4

    invoke-virtual {v2, v1, v5}, Landroid/database/sqlite/SQLiteDatabase;->rawQuery(Ljava/lang/String;[Ljava/lang/String;)Landroid/database/Cursor;

    move-result-object v0

    .line 386
    .restart local v0       #cursor:Landroid/database/Cursor;
    if-eqz v0, :cond_3

    invoke-interface {v0}, Landroid/database/Cursor;->getCount()I

    move-result v2

    if-eqz v2, :cond_3

    move-object v2, p1

    .line 387
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u53d6\u6d88\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 388
    const-string v2, "qq_unbind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    .line 393
    :goto_3
    if-eqz v0, :cond_0

    invoke-interface {v0}, Landroid/database/Cursor;->close()V

    goto :goto_1

    :cond_3
    move-object v2, p1

    .line 390
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 391
    const-string v2, "qq_bind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    goto :goto_3

    .line 394
    .end local v0           #cursor:Landroid/database/Cursor;
    :cond_4
    const-string v2, "netease"

    invoke-virtual {p3, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v2

    if-eqz v2, :cond_6

    .line 395
    const-string v1, "select * from oauth_list where oauth_type=?"

    .line 398
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    iget-object v2, v2, Lcom/netease/newsreader/activity/AccountSettingActivity;->db:Landroid/database/sqlite/SQLiteDatabase;

    new-array v5, v3, [Ljava/lang/String;

    const-string v6, "netease"

    aput-object v6, v5, v4

    invoke-virtual {v2, v1, v5}, Landroid/database/sqlite/SQLiteDatabase;->rawQuery(Ljava/lang/String;[Ljava/lang/String;)Landroid/database/Cursor;

    move-result-object v0

    .line 399
    .restart local v0       #cursor:Landroid/database/Cursor;
    if-eqz v0, :cond_5

    invoke-interface {v0}, Landroid/database/Cursor;->getCount()I

    move-result v2

    if-eqz v2, :cond_5

    move-object v2, p1

    .line 400
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u53d6\u6d88\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 401
    const-string v2, "netease_unbind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    .line 406
    :goto_4
    if-eqz v0, :cond_0

    invoke-interface {v0}, Landroid/database/Cursor;->close()V

    goto/16 :goto_1

    :cond_5
    move-object v2, p1

    .line 403
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 404
    const-string v2, "netease_bind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    goto :goto_4

    .line 407
    .end local v0           #cursor:Landroid/database/Cursor;
    :cond_6
    const-string v2, "renren"

    invoke-virtual {p3, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v2

    if-eqz v2, :cond_8

    .line 408
    const-string v1, "select * from oauth_list where oauth_type=?"

    .line 411
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    iget-object v2, v2, Lcom/netease/newsreader/activity/AccountSettingActivity;->db:Landroid/database/sqlite/SQLiteDatabase;

    new-array v5, v3, [Ljava/lang/String;

    const-string v6, "renren"

    aput-object v6, v5, v4

    invoke-virtual {v2, v1, v5}, Landroid/database/sqlite/SQLiteDatabase;->rawQuery(Ljava/lang/String;[Ljava/lang/String;)Landroid/database/Cursor;

    move-result-object v0

    .line 412
    .restart local v0       #cursor:Landroid/database/Cursor;
    if-eqz v0, :cond_7

    invoke-interface {v0}, Landroid/database/Cursor;->getCount()I

    move-result v2

    if-eqz v2, :cond_7

    move-object v2, p1

    .line 413
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u53d6\u6d88\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 414
    const-string v2, "renren_unbind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    .line 419
    :goto_5
    if-eqz v0, :cond_0

    invoke-interface {v0}, Landroid/database/Cursor;->close()V

    goto/16 :goto_1

    :cond_7
    move-object v2, p1

    .line 416
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 417
    const-string v2, "renren_bind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    goto :goto_5

    .line 420
    .end local v0           #cursor:Landroid/database/Cursor;
    :cond_8
    const-string v2, "ydnote"

    invoke-virtual {p3, v2}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v2

    if-eqz v2, :cond_0

    .line 421
    const-string v1, "select * from oauth_list where oauth_type=?"

    .line 424
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    iget-object v2, v2, Lcom/netease/newsreader/activity/AccountSettingActivity;->db:Landroid/database/sqlite/SQLiteDatabase;

    new-array v5, v3, [Ljava/lang/String;

    const-string v6, "ydnote"

    aput-object v6, v5, v4

    invoke-virtual {v2, v1, v5}, Landroid/database/sqlite/SQLiteDatabase;->rawQuery(Ljava/lang/String;[Ljava/lang/String;)Landroid/database/Cursor;

    move-result-object v0

    .line 425
    .restart local v0       #cursor:Landroid/database/Cursor;
    if-eqz v0, :cond_9

    invoke-interface {v0}, Landroid/database/Cursor;->getCount()I

    move-result v2

    if-eqz v2, :cond_9

    move-object v2, p1

    .line 426
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u53d6\u6d88\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 427
    const-string v2, "ydnote_unbind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    .line 432
    :goto_6
    if-eqz v0, :cond_0

    invoke-interface {v0}, Landroid/database/Cursor;->close()V

    goto/16 :goto_1

    :cond_9
    move-object v2, p1

    .line 429
    check-cast v2, Landroid/widget/Button;

    const-string v4, "\u7ed1\u5b9a"

    invoke-virtual {v2, v4}, Landroid/widget/Button;->setText(Ljava/lang/CharSequence;)V

    .line 430
    const-string v2, "ydnote_bind"

    invoke-virtual {p1, v2}, Landroid/view/View;->setTag(Ljava/lang/Object;)V

    goto :goto_6

    .line 438
    .end local v0           #cursor:Landroid/database/Cursor;
    .end local v1           #sql:Ljava/lang/String;
    :cond_a
    invoke-virtual {p1}, Landroid/view/View;->getId()I

    move-result v2

    const v3, 0x7f0c0013

    if-ne v2, v3, :cond_b

    .line 439
    iget-object v2, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    invoke-virtual {v2}, Lcom/netease/newsreader/activity/AccountSettingActivity;->getThemeSettingsHelper()Lcom/netease/newsreader/util/ThemeSettingsHelper;

    move-result-object v2

    iget-object v3, p0, Lcom/netease/newsreader/activity/AccountSettingActivity$ButtonItem;->this$0:Lcom/netease/newsreader/activity/AccountSettingActivity;

    check-cast p1, Landroid/widget/TextView;

    .end local p1
    invoke-virtual {v2, v3, p1, v7}, Lcom/netease/newsreader/util/ThemeSettingsHelper;->setTextViewColor(Landroid/content/Context;Landroid/widget/TextView;I)V

    :cond_b
    move v2, v4

    .line 441
    goto/16 :goto_2
.end method
